<%--
  Created by IntelliJ IDEA.
  User: zzz
  Date: 2020/2/7
  Time: 19:46
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="utf-8" />
    <title>个人信息</title>
    <link rel="stylesheet" type="text/css" href="${APP_PATH}/portal/css/public.css"/>
    <link rel="stylesheet" type="text/css" href="${APP_PATH}/portal/css/mygxin.css" />
</head>
<body>
<!------------------------------head------------------------------>
<jsp:include page="/WEB-INF/jsps/Portal/common/top.jsp"/>
<!------------------------------idea------------------------------>
<div class="address" id="add">
    <div class="wrapper clearfix">
        <a href="${APP_PATH}/toPortal" class="fl">首页</a>
        <span>/</span>
        <a href="${APP_PATH}/toUser" class="on">个人中心</a>
    </div>
</div>
<!------------------------------Bott------------------------------>
<div class="Bott">
    <div class="wrapper clearfix">
        <jsp:include page="/WEB-INF/jsps/Portal/common/nav.jsp"/>
        <div class="you fl">
            <div class="tx clearfix">
                <div class="fl clearfix">
                    <a href="#" class="fl"><img src="${APP_PATH}/portal/img/tx.png"/></a>
                    <p class="fl"><span>${sessionScope.user.unick}</span><a href="${APP_PATH}/toUpdateUser">修改个人信息></a></p>
                </div>
                <div class="fr">绑定邮箱：<span id="uemail"></span></div>
            </div>
            <div class="bott">

                <div class="clearfix">
                    <a href="#" class="fl"><img src="${APP_PATH}/portal/img/gxin2.jpg"/></a>
                    <p class="fl"><span>待收货的订单：<strong id="count"></strong></span>
                        <a href="${APP_PATH}/toMyOrder">查看待收货订单></a>
                    </p>
                </div>

            </div>
        </div>
    </div>
</div>



<!--返回顶部-->
<jsp:include page="/WEB-INF/jsps/Portal/common/gotop.jsp"/>
<jsp:include page="/WEB-INF/jsps/Portal/common/bottom.jsp"/>
<script src="${APP_PATH}/portal/js/jquery-1.12.4.min.js" type="text/javascript" charset="utf-8"></script>
<script src="${APP_PATH}/portal/js/public.js" type="text/javascript" charset="utf-8"></script>
<script src="${APP_PATH}/portal/js/user.js" type="text/javascript" charset="utf-8"></script>

</body>
</html>

<script>
    $(function () {
        var uemail = '${sessionScope.user.uemail}';
        var content = uemail.split("@")[0];
        var hideContent = "";
        hideContent += content.substr(0,2);
        for(var i = 0; i < content.length-3; i ++){
            hideContent += "*";
        }
        hideContent += content.substr(-1,1)+"@"+uemail.split("@")[1];
       $("#uemail").html(hideContent);

       $.ajax({
           url : "${APP_PATH}/order/findOrderCountByOtype",
           method : "GET",
           data : {
               otype : 1
           },
           success : function (result) {
               if(result.success){
                    $("#count").html(result.data);
               }
           }
       });
    });
</script>